package com.ww.learn.collection

fun getTemperatureAtAirport(code: String): String = "${Math.round(Math.random() * 30.0) + code.count()} C"

fun main() {
    val airportCodes = listOf("LAX", "SFO", "PDX", "SEA")

    val temperatures = airportCodes.map { code -> code to getTemperatureAtAirport(code) }

    for (temp in temperatures) {
        println("Airport: ${temp.first}: Temperature: ${temp.second}")
    }
}